Skip to content

ci-automation: enable OCI testing#4143

Draft
tormath1 wants to merge 2 commits into
mainfrom
tormath1/oci
Draft

ci-automation: enable OCI testing#4143
tormath1 wants to merge 2 commits into
mainfrom
tormath1/oci

Conversation

@tormath1

@tormath1 tormath1 commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

In this PR, we enable OCI (OracleCloud Infrastructure) testing for Flatcar. Promoting OCI to "officially" supported platform.

Testing done

Tested here: https://jenkins.flatcar.org/job/container/job/test_dispatcher/389/


TODO:

  • Add arm64 instance type
  • Changelog entries added in the respective changelog/ directory (user-facing change, bug fix, security fix, update)
  • Inspected CI output for image differences: /boot and /usr size, packages, list files for any missing binaries, kernel modules, config files, kernel modules, etc.

Needs:

@tormath1 tormath1 self-assigned this Jul 16, 2026
Copilot AI review requested due to automatic review settings July 16, 2026 14:19
@tormath1 tormath1 changed the title Tormath1/oci ci-automation: enable OCI testing Jul 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Enables OracleCloud Infrastructure (OCI) vendor testing within the CI automation scripts, aiming to promote OCI as an officially supported platform by adding a new vendor test runner, OCI-related environment configuration, and OCI garbage collection.

Changes:

  • Added a new OCI vendor test wrapper script (oraclecloud.sh) that uploads an image via ore oracle and runs kola tests against it.
  • Extended cloud garbage collection to include OCI image cleanup via ore oracle gc.
  • Introduced OCI-related CI configuration defaults (image name, subnet, instance types/locations).

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
ci-automation/vendor-testing/oraclecloud.sh New OCI vendor test wrapper that uploads an OCI image and runs kola on OCI.
ci-automation/garbage_collect_cloud.sh Adds OCI garbage collection using ore oracle gc.
ci-automation/ci-config.env Adds OCI CI configuration defaults (image name, subnet, instance type/location).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +43 to +45
--basename="${kola_test_basename}" \
# TODO: Update to oraclecloud
--platform=oracle \
Comment on lines +175 to +178
# TODO: Use actual values for ARM64
: ${ORACLECLOUD_arm64_INSTANCE_TYPE:="g1r.4d"}
: ${ORACLECLOUD_arm64_LOCATION:="YQPA:US-ASHBURN-AD-1"}
: ${ORACLECLOUD_amd64_LOCATION:="YQPA:US-ASHBURN-AD-1"}
Copilot AI review requested due to automatic review settings July 20, 2026 09:55

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

Comment on lines +11 to +18
source ci-automation/vendor_test.sh

oraclecloud_instance_type_var="ORACLECLOUD_${CIA_ARCH}_INSTANCE_TYPE"
oraclecloud_instance_type="${!oraclecloud_instance_type_var}"

oraclecloud_location_var="ORACLECLOUD_${CIA_ARCH}_LOCATION"
oraclecloud_location="${!oraclecloud_location_var}"

Comment on lines +36 to +57
set -x

timeout --signal=SIGQUIT 2h kola run \
--board="${CIA_ARCH}-usr" \
--parallel="${ORACLECLOUD_PARALLEL}" \
--tapfile="${CIA_TAPFILE}" \
--channel="${CIA_CHANNEL}" \
--basename="${kola_test_basename}" \
--platform=oraclecloud \
--oraclecloud-tenancy="${ORACLECLOUD_TENANCY}" \
--oraclecloud-user="${ORACLECLOUD_USER}" \
--oraclecloud-fingerprint="${ORACLECLOUD_FINGERPRINT}" \
--oraclecloud-private-key=<(echo "${ORACLECLOUD_PRIVATE_KEY}" | base64 --decode) \
--oraclecloud-image-id="${IMAGE_ID}" \
--oraclecloud-shape="${oraclecloud_instance_type}" \
--oraclecloud-subnet-id="${ORACLECLOUD_SUBNET_ID}" \
--oraclecloud-availability-domain="${oraclecloud_location}" \
--oraclecloud-compartment-id="${ORACLECLOUD_COMPARTMENT_ID}" \
--image-version "${CIA_VERNUM}" \
"${@}"

set +x
Comment on lines +27 to +33
IMAGE_ID=$(ore oracle \
--oracle-config-file="${config_file}" \
--oracle-compartment-id="${ORACLECLOUD_COMPARTMENT_ID}" \
create-image \
--board "${CIA_ARCH}-usr" \
--name "${kola_test_basename}" \
--file="${ORACLECLOUD_IMAGE_NAME}"
Comment on lines +28 to +33
timeout --signal=SIGQUIT 60m ore oraclecloud gc --duration 6h \
--oraclecloud-tenancy="${ORACLECLOUD_TENANCY}" \
--oraclecloud-user="${ORACLECLOUD_USER}" \
--oraclecloud-fingerprint="${ORACLECLOUD_FINGERPRINT}" \
--oraclecloud-private-key=<(echo "${ORACLECLOUD_PRIVATE_KEY}" | base64 --decode) \
--oraclecloud-compartment-id="${ORACLECLOUD_COMPARTMENT_ID}"
Comment thread ci-automation/ci-config.env Outdated
# -- OracleCloud --
ORACLECLOUD_PARALLEL="${PARALLEL_TESTS:-1}"
ORACLECLOUD_IMAGE_NAME="flatcar_production_oraclecloud_image.img"
ORACLECLOUD_SUBNET_ID="ocid1.subnet.oc1.iad.aaaaaaaaafwj2g3ojrn7j2mlk4nnbaq27o4cxelrxstlaymm6ecs76xtb2aa"
Copilot AI review requested due to automatic review settings July 20, 2026 13:14

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comments suppressed due to low confidence (2)

ci-automation/vendor-testing/oraclecloud.sh:41

  • set -x is enabled before kola run, and the private key is currently injected via process substitution that expands ${ORACLECLOUD_PRIVATE_KEY} inline. With xtrace enabled, bash may emit the expanded secret into logs. Consider decoding the key via secret_to_file with xtrace temporarily disabled, then pass the resulting path to kola.
set -x

timeout --signal=SIGQUIT 2h kola run \
  --board="${CIA_ARCH}-usr" \
  --parallel="${ORACLECLOUD_PARALLEL}" \

ci-automation/ci-config.env:173

  • ORACLECLOUD_SUBNET_ID is assigned unconditionally, which prevents overriding it via environment variables (unlike most other cloud-specific settings in this file that use : ${VAR:=...}). Making it a default assignment keeps CI working while allowing overrides for other environments/forks.
ORACLECLOUD_SUBNET_ID="ocid1.subnet.oc1.iad.aaaaaaaaafwj2g3ojrn7j2mlk4nnbaq27o4cxelrxstlaymm6ecs76xtb2aa"

Comment on lines +31 to +33
--oraclecloud-fingerprint="${ORACLECLOUD_FINGERPRINT}" \
--oraclecloud-private-key-file=<(echo "${ORACLECLOUD_PRIVATE_KEY}" | base64 --decode) \
--oraclecloud-compartment-id="${ORACLECLOUD_COMPARTMENT_ID}"
Comment on lines +28 to +30
timeout --signal=SIGQUIT 60m ore oraclecloud gc --duration 6h \
--oraclecloud-tenancy="${ORACLECLOUD_TENANCY}" \
--oraclecloud-user="${ORACLECLOUD_USER}" \
tormath1 added 2 commits July 20, 2026 15:59
In this commit, we setup oraclecloud testing using SDK and Mantle.

Signed-off-by: Mathieu Tortuyaux <mtortuyaux@microsoft.com>
Signed-off-by: Mathieu Tortuyaux <mtortuyaux@microsoft.com>
Copilot AI review requested due to automatic review settings July 20, 2026 13:59

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (2)

ci-automation/vendor-testing/oraclecloud.sh:33

  • oraclecloud_private_key_path is already created via secret_to_file, but ore oraclecloud create-image decodes ${ORACLECLOUD_PRIVATE_KEY} again via process substitution. This duplicates secret-handling logic and makes the create-image path inconsistent with the subsequent kola run/GC usage. Reuse the existing oraclecloud_private_key_path for the ore call as well.
IMAGE_ID=$(ore oraclecloud \
  --oraclecloud-compartment-id="${ORACLECLOUD_COMPARTMENT_ID}" \
  --oraclecloud-tenancy="${ORACLECLOUD_TENANCY}" \
  --oraclecloud-user="${ORACLECLOUD_USER}" \
  --oraclecloud-fingerprint="${ORACLECLOUD_FINGERPRINT}" \
  --oraclecloud-private-key-path=<(echo "${ORACLECLOUD_PRIVATE_KEY}" | base64 --decode) \
  create-image \

ci-automation/ci-config.env:176

  • The default ORACLECLOUD_arm64_INSTANCE_TYPE is set to g1r.4d, which matches the STACKIT arm64 flavor naming in this same file and does not match the OCI shape naming used for amd64 (e.g. VM.Standard3.Flex). Keeping an obviously non-OCI default here will cause arm64 OracleCloud runs to fail in a confusing way; better to leave it unset until real OCI arm64 values are added so the vendor test fails fast if someone tries to enable arm64 prematurely.
# TODO: Use actual values for ARM64
: ${ORACLECLOUD_arm64_INSTANCE_TYPE:="g1r.4d"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants